package com.shared.model;

import javax.persistence.Id;

import com.googlecode.objectify.annotation.Entity;
import com.shared.data.IData;
@Entity
public class Tarification implements IData {

	@Id private Long key;
	private double montantHonoraires ;
	private double fraisCourtage ;
	private double montantCommissions ;
	private double montantCourtage ;
	private double montantCompagnie ;
	private double taxeAssurance ;	
	private double montantCommissionCATNAT ;
		
	
	
	public Tarification() {	}
	
	public Tarification(double montantHonoraires, double fraisCourtage,double montantCommissions,double montantCourtage,double montantCompagnie,double taxeAssurance,double montantCommissionCATNAT) {
		this.montantHonoraires = montantHonoraires;
		this.setFraisCourtage(fraisCourtage);
		this.montantCommissions = montantCommissions;
		this.montantCourtage = montantCourtage;
		this.montantCompagnie = montantCompagnie;
		this.taxeAssurance = taxeAssurance;
		this.setMontantCommissionCATNAT(montantCommissionCATNAT);
	}
	
	/**
	 * @return the montantHonoraires
	 */
	public double getMontantHonoraires() {
		return montantHonoraires;
	}

	/**
	 * @param montantHonoraires the montantHonoraires to set
	 */
	public void setMontantHonoraires(double montantHonoraires) {
		this.montantHonoraires = montantHonoraires;
	}

	/**
	 * @return the montantCommissions
	 */
	public double getMontantCommissions() {
		return montantCommissions;
	}

	/**
	 * @param montantCommissions the montantCommissions to set
	 */
	public void setMontantCommissions(double montantCommissions) {
		this.montantCommissions = montantCommissions;
	}

	/**
	 * @return the montantCourtage
	 */
	public double getMontantCourtage() {
		return montantCourtage;
	}

	/**
	 * @param montantCourtage the montantCourtage to set
	 */
	public void setMontantCourtage(double montantCourtage) {
		this.montantCourtage = montantCourtage;
	}

	/**
	 * @return the montantCompagnie
	 */
	public double getMontantCompagnie() {
		return montantCompagnie;
	}

	/**
	 * @param montantCompagnie the montantCompagnie to set
	 */
	public void setMontantCompagnie(double montantCompagnie) {
		this.montantCompagnie = montantCompagnie;
	}

	/**
	 * @return the taxeAssurance
	 */
	public double getTaxeAssurance() {
		return taxeAssurance;
	}

	/**
	 * @param taxeAssurance the taxeAssurance to set
	 */
	public void setTaxeAssurance(double taxeAssurance) {
		this.taxeAssurance = taxeAssurance;
	}

	public double getMontantHT(){
		return (montantCompagnie - taxeAssurance + montantCommissions) ;
		
	}
	
	public double getMontantTTC(){
		return (getMontantHT() + taxeAssurance) ;
		
	}
	
	public double getMontantTotal(){
		return (getMontantTTC() + montantCourtage + montantHonoraires) ;
		
	}

	/**
	 * @param key the key to set
	 */
	public void setKey(Long key) {
		this.key = key;
	}

	/**
	 * @return the key
	 */
	public Long getKey() {
		return key;
	}

	/**
	 * @param fraisCourtage the fraisCourtage to set
	 */
	public void setFraisCourtage(double fraisCourtage) {
		this.fraisCourtage = fraisCourtage;
	}

	/**
	 * @return the fraisCourtage
	 */
	public double getFraisCourtage() {
		return fraisCourtage;
	}

	/**
	 * @param montantCommissionCATNAT the montantCommissionCATNAT to set
	 */
	public void setMontantCommissionCATNAT(double montantCommissionCATNAT) {
		this.montantCommissionCATNAT = montantCommissionCATNAT;
	}

	/**
	 * @return the montantCommissionCATNAT
	 */
	public double getMontantCommissionCATNAT() {
		return montantCommissionCATNAT;
	}

	
	
}
